import React, { Component } from "react";
import "./index.css";
import cards from "./cards";
import Card from "./Card.jsx";

class Home extends Component {
  constructor(props) {
    super(props);
  }

  render() {
    return (
      <React.Fragment>
        <div className="carsourel center">
          <div className="bg-cover">
            <div className="container">
              <div className="title tc">
                <span>记录成长 分享生活</span>
              </div>
              <div className="desc tc">一个90后程序员，终身学习者。</div>
            </div>
          </div>
        </div>
        <main className="index-card">
          <div className="container">
            <div className="card-content">
              <div className="card-row">
                <p className="title">我的寄语</p>
                <p className="comment">
                  永远积极向上，永远热泪盈眶，永远心怀梦想，永远充满正能量。
                </p>
              </div>
            </div>
            <div className="articles">
              {cards.map(function (item) {
                return <Card card={item} key={item.title}></Card>;
              })}
            </div>
          </div>
        </main>
      </React.Fragment>
    );
  }
}

export default Home;
